home *** CD-ROM | disk | FTP | other *** search
/ Amiga Tools 2 / Amiga Tools 2.iso / mui / mui-tools / multiuser / auto / multiuser.doc
Text File  |  1995-03-09  |  32KB  |  1,003 lines

  1. TABLE OF CONTENTS
  2.  
  3. multiuser.library/--background--
  4. multiuser.library/muAddMonitor
  5. multiuser.library/muAllocGroupInfo
  6. multiuser.library/muAllocUserInfo
  7. multiuser.library/muCheckPasswd
  8. multiuser.library/muExtOwner2ULONG
  9. multiuser.library/muFreeExtOwner
  10. multiuser.library/muFreeGroupInfo
  11. multiuser.library/muFreeUserInfo
  12. multiuser.library/muFreeze
  13. multiuser.library/muGetConfigDirLock
  14. multiuser.library/muGetDefProtection
  15. multiuser.library/muGetGroupInfo
  16. multiuser.library/muGetPasswdDirLock
  17. multiuser.library/muGetRelationshipA
  18. multiuser.library/muGetTaskExtOwner
  19. multiuser.library/muGetTaskOwner
  20. multiuser.library/muGetUserInfo
  21. multiuser.library/muKill
  22. multiuser.library/muLimitDOSSetProtection
  23. multiuser.library/muLoginA
  24. multiuser.library/muLogoutA
  25. multiuser.library/muPasswd
  26. multiuser.library/muRemMonitor
  27. multiuser.library/muSetDefProtectionA
  28. multiuser.library/muSetProtection
  29. multiuser.library/muUnfreeze
  30. multiuser.library/muUserInfo2ExtOwner
  31. multiuser.library/--background--             multiuser.library/--background--
  32.  
  33.   PURPOSE
  34.  
  35.     MultiUser  was  developed  to  get  a  greather  access  control than the
  36.     standard  Amiga Operating System provided.  It lets several users work on
  37.     the same computer - even at the same time - without losing their privacy.
  38.  
  39.   OVERVIEW
  40.  
  41.     * Users
  42.  
  43.       A user can only use the system if he/she is authorized to login.
  44.  
  45.     * Groups
  46.  
  47.       Every  user belongs to at least one group - his/her primary group - and
  48.       may belong to some secondary groups too.
  49.  
  50.     * Tasks/processess
  51.  
  52.       Every task or process is owned by a user.
  53.  
  54.     * Objects
  55.  
  56.       Objects  are  owned by a user (specified by his user identifier and one
  57.       of his group identifiers) and generally contain some access flags which
  58.       define  whether  someone has access to the object or not.  There can be
  59.       three kinds of access flags:
  60.  
  61.         - flags for the owner of the object
  62.  
  63.         - flags  for  a user who belongs to the same group as stored with the
  64.           object
  65.  
  66.         - flags for other users
  67.  
  68.       E.g.   the  objects  used  with  the  MultiUserFileSystem are files and
  69.       directories, the access flags are the protection bits.
  70.  
  71.     * Access control
  72.  
  73.       If  a  user  requests access to an object, the system can check whether
  74.       he/she  has  access  or  not  via  the  owner of the requesting task or
  75.       process and via the owner of the wanted object using the access flags.
  76.  
  77.  
  78. multiuser.library/muAddMonitor                 multiuser.library/muAddMonitor
  79.  
  80.   NAME  muAddMonitor()  (V39)
  81.  
  82.     success = muAddMonitor(monitor);
  83.  
  84.     BOOL muAddMonitor(struct muMonitor *);
  85.     D0                A0
  86.  
  87.   DESCRIPTION
  88.     Add a monitor to the system.  Depending on the monitor flags, you will be
  89.     notified    on   some   actions   via   a   signal   or   message.    See
  90.     <libraries/multiuser.h> for more information.  This call may be made only
  91.     by root.
  92.  
  93.   INPUTS
  94.     monitor - an initialised muMonitor structure.
  95.  
  96.   RESULT
  97.     success - success indicator.
  98.  
  99.   BUGS
  100.     none known
  101.  
  102.   SEE ALSO
  103.     muRemMonitor(), <libraries/multiuser.h>
  104.  
  105. multiuser.library/muAllocGroupInfo         multiuser.library/muAllocGroupInfo
  106.  
  107.   NAME  muAllocGroupInfo()  (V39)
  108.  
  109.     info = muAllocGroupInfo();
  110.  
  111.     struct muGroupInfo *muAllocGroupInfo(void);
  112.     D0
  113.  
  114.   DESCRIPTION
  115.     Allocate  a muGroupInfo structure in a future compatible manner.  This is
  116.     the  only  valid  way to allocate a muGroupInfo structure.  The structure
  117.     will be made empty for you.
  118.  
  119.   INPUTS
  120.     none
  121.  
  122.   RESULT
  123.     info - pointer  to  the  allocated  muGroupInfo  structure or NULL for no
  124.            memory.
  125.  
  126.   BUGS
  127.     none known
  128.  
  129.   SEE ALSO
  130.     muFreeGroupInfo(), muGetGroupInfo()
  131.  
  132. multiuser.library/muAllocUserInfo           multiuser.library/muAllocUserInfo
  133.  
  134.   NAME  muAllocUserInfo()  (V39)
  135.  
  136.     info = muAllocUserInfo();
  137.  
  138.     struct muUserInfo *muAllocUserInfo(void);
  139.     D0
  140.  
  141.   DESCRIPTION
  142.     Allocate  a  muUserInfo structure in a future compatible manner.  This is
  143.     the  only  valid  way  to allocate a muUserInfo structure.  The structure
  144.     will be made empty for you.
  145.  
  146.   INPUTS
  147.     none
  148.  
  149.   RESULT
  150.     info - pointer  to  the  allocated  muUserInfo  structure  or NULL for no
  151.            memory.
  152.  
  153.   BUGS
  154.     none known
  155.  
  156.   SEE ALSO
  157.     muFreeUserInfo(), muGetUserInfo()
  158.  
  159. multiuser.library/muCheckPasswd               multiuser.library/muCheckPasswd
  160.  
  161.   NAME  muCheckPasswd()  (V39)
  162.  
  163.     valid = muCheckPasswd(taglist);
  164.  
  165.     BOOL  muCheckPasswd(struct TagItem *);
  166.     D0                  A0
  167.  
  168.   DESCRIPTION
  169.     Check  whether  the supplied password is the valid password for the owner
  170.     of the current task.
  171.     This  function  is mainly intended to support SysLock look-alike programs
  172.     (cfr.  XLock for the MIT's X Window System).
  173.  
  174.   TAGS
  175.     muT_Password - (STRPTR)
  176.                    The password.
  177.  
  178.   INPUTS
  179.     taglist - a pointer to a taglist (may be NULL).
  180.  
  181.   RESULT
  182.     valid - indicates the password is valid.
  183.  
  184.   NOTE
  185.     This  function  may  be  extended  in future to let the super user (root)
  186.     check passwords for other tasks.
  187.  
  188.   BUGS
  189.     none known
  190.  
  191.   SEE ALSO
  192.     muPasswd()
  193.  
  194. multiuser.library/muExtOwner2ULONG         multiuser.library/muExtOwner2ULONG
  195.  
  196.   NAME  muExtOwner2ULONG()  (V39)
  197.  
  198.     user = muExtOwner2ULONG(owner);
  199.  
  200.     ULONG muExtOwner2ULONG(struct muExtOwner *);
  201.  
  202.   DESCRIPTION
  203.     This  macro  converts  a  muExtOwner  structure  to  a  ULONG  (cfr.  the
  204.     difference between muGetTaskExtOwner() and muGetTaskOwner()).
  205.  
  206.   INPUTS
  207.     owner - a  structure  returned by muGetTaskExtOwner() (may be NULL).  You
  208.             still have to free this structure by yourself!
  209.  
  210.   RESULT
  211.     user - the  bits  31-16  specify the user id (uid), the bits 15-0 specify
  212.            the group id (gid).  NULL for nobody.
  213.  
  214.   BUGS
  215.     none known
  216.  
  217.   SEE ALSO
  218.     muGetTaskExtOwner(), muGetTaskOwner(), muGetRelationshipA()
  219.  
  220. multiuser.library/muFreeExtOwner             multiuser.library/muFreeExtOwner
  221.  
  222.   NAME  muFreeExtOwner()  (V39)
  223.  
  224.     muFreeExtOwner(info);
  225.  
  226.     void muFreeExtOwner(struct muExtOwner *);
  227.                         A0
  228.  
  229.   DESCRIPTION
  230.     Free   a   muExtOwner   structure   returned   by   muGetTaskExtOwner  or
  231.     muUserInfo2ExtOwner.
  232.  
  233.   INPUTS
  234.     info - a  pointer  to  the muExtOwner structure you want to free.  May be
  235.            NULL.
  236.  
  237.   RESULT
  238.     none
  239.  
  240.   BUGS
  241.     none known
  242.  
  243.   SEE ALSO
  244.     muGetTaskExtOwner(), muUserInfo2ExtOwner
  245.  
  246. multiuser.library/muFreeGroupInfo           multiuser.library/muFreeGroupInfo
  247.  
  248.   NAME  muFreeGroupInfo()  (V39)
  249.  
  250.     muFreeGroupInfo(info);
  251.  
  252.     void muFreeGroupInfo(struct muGroupInfo *);
  253.                          A0
  254.  
  255.   DESCRIPTION
  256.     Free a muGroupInfo structure allocated with muAllocGroupInfo.
  257.  
  258.   INPUTS
  259.     info - a  pointer  to the muGroupInfo structure you want to free.  May be
  260.            NULL.
  261.  
  262.   RESULT
  263.     none
  264.  
  265.   BUGS
  266.     none known
  267.  
  268.   SEE ALSO
  269.     muAllocGroupInfo(), muGetGroupInfo()
  270.  
  271. multiuser.library/muFreeUserInfo             multiuser.library/muFreeUserInfo
  272.  
  273.   NAME  muFreeUserInfo()  (V39)
  274.  
  275.     muFreeUserInfo(info);
  276.  
  277.     void muFreeUserInfo(struct muUserInfo *);
  278.                         A0
  279.  
  280.   DESCRIPTION
  281.     Free a muUserInfo structure allocated with muAllocUserInfo.
  282.  
  283.   INPUTS
  284.     info - a  pointer  to  the muUserInfo structure you want to free.  May be
  285.            NULL.
  286.  
  287.   RESULT
  288.     none
  289.  
  290.   BUGS
  291.     none known
  292.  
  293.   SEE ALSO
  294.     muAllocUserInfo(), muGetUserInfo()
  295.  
  296. multiuser.library/muFreeze                         multiuser.library/muFreeze
  297.  
  298.   NAME  muFreeze()  (V39)
  299.  
  300.     success = muFreeze(task);
  301.  
  302.     BOOL muFreeze(struct Task *);
  303.     D0            A0
  304.  
  305.   DESCRIPTION
  306.     Freeze   a   specified   task.    You  cannot  freeze  yourself  nor  the
  307.     MultiUser.server.  This call may be made only by root.
  308.  
  309.   INPUTS
  310.     task - a pointer to the task you want to freeze.
  311.  
  312.   RESULT
  313.     success - success indicator.
  314.  
  315.   BUGS
  316.     none known
  317.  
  318.   SEE ALSO
  319.     muKill(), muUnfreeze()
  320.  
  321. multiuser.library/muGetConfigDirLock     multiuser.library/muGetConfigDirLock
  322.  
  323.   NAME  muGetConfigDirLock()  (V39)
  324.  
  325.     lock = muGetConfigDirLock();
  326.  
  327.     BPTR muGetConfigDirLock(void);
  328.     D0
  329.  
  330.   DESCRIPTION
  331.     Get  a  shared lock on the directory of the configuration and group file.
  332.     The names of these files are defined in <libraries/multiuser.h>.  If this
  333.     call succeeds, you must free the returned lock by yourself.
  334.     This function is mainly intended to support configuration tools.
  335.  
  336.   INPUTS
  337.     none
  338.  
  339.   RESULT
  340.     lock - the desired lock, or NULL for failure.
  341.  
  342.   BUGS
  343.     none known
  344.  
  345.   SEE ALSO
  346.     muGetPasswdDirLock(), <libraries/multiuser.h>
  347.  
  348. multiuser.library/muGetDefProtection     multiuser.library/muGetDefProtection
  349.  
  350.   NAME  muGetDefProtection()  (V39)
  351.  
  352.     mask = muGetDefProtection(task);
  353.  
  354.     ULONG muGetDefProtection(struct Task *);
  355.     D0                       D0
  356.  
  357.   DESCRIPTION
  358.     Get the default protection bits related to a task.
  359.  
  360.   INPUTS
  361.     task - a  pointer  to  the  task  for  which you want to know the default
  362.            protection bits, or NULL for the current task.
  363.  
  364.   RESULT
  365.     mask - the  default protection bits.  They are in the format like defined
  366.            in <dos/dos.h>.
  367.  
  368.   BUGS
  369.     none known
  370.  
  371.   SEE ALSO
  372.     muSetDefProtectionA(), <dos/dos.h>
  373.  
  374. multiuser.library/muGetGroupInfo             multiuser.library/muGetGroupInfo
  375.  
  376.   NAME  muGetGroupInfo()  (V39)
  377.  
  378.     info = muGetGroupInfo(info, keytype);
  379.  
  380.     struct muGroupInfo *muGetGroupInfo(struct muGroupInfo *, ULONG);
  381.     D0                                 A0                    D0
  382.  
  383.   DESCRIPTION
  384.     Get  information about a group.  You must pass in a muGroupInfo structure
  385.     and  a  keytype, which defines the type of information you have filled in
  386.     in  the  muGroupInfo structure about the wanted group(s).  Valid keytypes
  387.     are:
  388.  
  389.       muKeyType_First          - find  the  first  group.   You don't have to
  390.                                  fill   in  any  fields  in  the  muGroupInfo
  391.                                  structure.
  392.       muKeyType_Next           - find  the  next  group.  Use this only after
  393.                                  you've  made  a call with muKeyType_First as
  394.                                  keytype.
  395.       muKeyType_GroupID        - find  a group with a specific GroupID.  Fill
  396.                                  in   the   field   GroupID   before  calling
  397.                                  muGetGroupInfo().   The  search will be case
  398.                                  sensitive.
  399.       muKeyType_WGroupID       - find  a group with a specific GroupID.  Fill
  400.                                  in   the   field   GroupID   before  calling
  401.                                  muGetGroupInfo().   The  search will be case
  402.                                  insensitive, wild cards are allowed.
  403.       muKeyType_WGroupIDNext   - find the next group with a specific GroupID.
  404.                                  Use  this only after you've made a call with
  405.                                  muKeyType_WGroupID as keytype.
  406.       muKeyType_gid            - find  a  group with a specific gid.  Fill in
  407.                                  the     field     gid     before     calling
  408.                                  muGetGroupInfo().
  409.       muKeyType_GroupName      - find  a  group  with  a  specific GroupName.
  410.                                  Fill  in  the field GroupName before calling
  411.                                  muGetGroupInfo().   The  search will be case
  412.                                  insensitive.
  413.       muKeyType_WGroupName     - find  a  group  with  a  specific GroupName.
  414.                                  Fill  in  the field GroupName before calling
  415.                                  muGetGroupInfo().   The  search will be case
  416.                                  insensitive, wild cards are allowed.
  417.       muKeyType_WGroupNameNext - find   the   next   group  with  a  specific
  418.                                  GroupName.   Use this only after you've made
  419.                                  a call with muKeyType_WGroupName as keytype.
  420.       muKeyType_MgrUid         - find  a  group  which  is managed by a user,
  421.                                  specified  by  his  uid.   Fill in the field
  422.                                  MgrUid before calling muGetGroupInfo().
  423.       muKeyType_MgrUidNext     - find  the  next  group which is managed by a
  424.                                  specified  user.  Use this only after you've
  425.                                  made   a   call   with  muKeyType_MgrUid  as
  426.                                  keytype.
  427.  
  428.   INPUTS
  429.     info    - a muGroupInfo structure, allocated with muAllocGroupInfo.
  430.     keytype - the magic keytype.
  431.  
  432.   RESULT
  433.     info - a  pointer  to  the  supplied muGroupInfo structure, or NULL for a
  434.            failure.
  435.  
  436.   NOTE
  437.     Do  not  change  the  contents of a muGroupInfo structure before calls to
  438.     muGetGroupInfo()     with     muKeyType_Next,     muKeyType_WGroupIDNext,
  439.     muKeyType_WGroupNameNext or muKeyType_MgrUidNext.
  440.  
  441.   BUGS
  442.     none known
  443.  
  444.   SEE ALSO
  445.     muAllocGroupInfo(), muGetGroupInfo(), <libraries/multiuser.h>,
  446.     dos.library/SetOwner()
  447.  
  448. multiuser.library/muGetPasswdDirLock     multiuser.library/muGetPasswdDirLock
  449.  
  450.   NAME  muGetPasswdDirLock()  (V39)
  451.  
  452.     lock = muGetPasswdDirLock();
  453.  
  454.     BPTR muGetPasswdDirLock(void);
  455.     D0
  456.  
  457.   DESCRIPTION
  458.     Get a shared lock on the directory of the password file.  The name of the
  459.     password  file  is  defined  in  <libraries/multiuser.h>.   If  this call
  460.     succeeds, you must free the returned lock by yourself.
  461.     This function is mainly intended to support configuration tools.
  462.  
  463.   INPUTS
  464.     none
  465.  
  466.   RESULT
  467.     lock - the desired lock, or NULL for failure.
  468.  
  469.   BUGS
  470.     none known
  471.  
  472.   SEE ALSO
  473.     muGetConfigDirLock(), <libraries/multiuser.h>
  474.  
  475. multiuser.library/muGetRelationshipA     multiuser.library/muGetRelationshipA
  476.  
  477.   NAME  muGetRelationshipA()  (V39)
  478.  
  479.     flags = muGetRelationshipA(user, owner, taglist);
  480.  
  481.     ULONG muGetRelationshipA(struct muExtOwner *, ULONG, struct TagItem *);
  482.     D0                       D0                   D1     A0
  483.  
  484.   DESCRIPTION
  485.     Get  the  access  relationship  the user has to an object owned by owner.
  486.     You're  strongly advised to use this function for access checking in your
  487.     own  programs  too,  since  this functions contains the 'official' access
  488.     rights policy, which may be extended or changed in future.  This function
  489.     has been made as fast as possible.
  490.  
  491.   TAGS
  492.     No tags are currently defined.
  493.  
  494.   INPUTS
  495.     user    - the  user  requesting  access  to  the  object,  as returned by
  496.               muGetTaskExtOwner() (may be NULL).
  497.     owner   - the  owner of the object (i.e.  his uid/gid).  Pass NULL if you
  498.               just want to check if the user is root or nobody.
  499.     taglist - a pointer to a taglist (may be NULL).
  500.  
  501.   RESULT
  502.     flags - relationship flags, as defined in <libraries/multiuser.h>.
  503.  
  504.   BUGS
  505.     none known
  506.  
  507.   SEE ALSO
  508.     muGetTaskExtOwner(), <libraries/multiuser.h>
  509.  
  510. multiuser.library/muGetTaskExtOwner       multiuser.library/muGetTaskExtOwner
  511.  
  512.   NAME  muGetTaskExtOwner()  (V39)
  513.  
  514.     user = muGetTaskExtOwner(task);
  515.  
  516.     struct muExtOwner *muGetTaskExtOwner(struct Task *);
  517.     D0                                   D0
  518.  
  519.   DESCRIPTION
  520.     Get  the owner of a task.  Unlike muGetTaskOwner(), this function returns
  521.     a structure which contains the secondary groups the user belongs to, too.
  522.     Do not forget to free the returned structure with muFreeExtOwner().
  523.  
  524.   INPUTS
  525.     task - a pointer to the task of which you want to know the owner, or NULL
  526.            for the current task.
  527.  
  528.   RESULT
  529.     user - a  pointer to a structure containing information about the user of
  530.            the  specified  task.   This  may  (but  mostly won't) be NULL for
  531.            nobody.   You  must  use  muFreeExtOwner()  to free this structure
  532.            after use.  You may not alter this structure.
  533.  
  534.   BUGS
  535.     none known
  536.  
  537.   SEE ALSO
  538.     muFreeExtOwner(), muGetRelationshipA(), muGetUserInfo()
  539.  
  540. multiuser.library/muGetTaskOwner             multiuser.library/muGetTaskOwner
  541.  
  542.   NAME  muGetTaskOwner()  (V39)
  543.  
  544.     user = muGetTaskOwner(task);
  545.  
  546.     ULONG muGetTaskOwner(struct Task *);
  547.     D0                   D0
  548.  
  549.   DESCRIPTION
  550.     Get the owner of a task.  Use muGetTaskExtOwner() if you want information
  551.     about the owner's secondary groups too.
  552.  
  553.   INPUTS
  554.     task - a pointer to the task of which you want to know the owner, or NULL
  555.            for the current task.
  556.  
  557.   RESULT
  558.     user - the owner of the specified task.  The bits 31-16 specify the owner
  559.            user  id  (uid),  the  bits 15-0 specify the owner group id (gid).
  560.            NULL for nobody.
  561.  
  562.   BUGS
  563.     none known
  564.  
  565.   SEE ALSO
  566.     muGetTaskExtOwner(), muGetUserInfo()
  567.  
  568. multiuser.library/muGetUserInfo               multiuser.library/muGetUserInfo
  569.  
  570.   NAME  muGetUserInfo()  (V39)
  571.  
  572.     info = muGetUserInfo(info, keytype);
  573.  
  574.     struct muUserInfo *muGetUserInfo(struct muUserInfo *, ULONG);
  575.     D0                               A0                   D0
  576.  
  577.   DESCRIPTION
  578.     Get  information  about  a user.  You must pass in a muUserInfo structure
  579.     and  a  keytype, which defines the type of information you have filled in
  580.     in  the  muUserInfo  structure  about the wanted user(s).  Valid keytypes
  581.     are:
  582.  
  583.       muKeyType_First         - find  the first user.  You don't have to fill
  584.                                 in any fields in the muUserInfo structure.
  585.       muKeyType_Next          - find  the  next  user.   Use  this only after
  586.                                 you've  made  a  call with muKeyType_First as
  587.                                 keytype.
  588.       muKeyType_UserID        - find  a user with a specific UserID.  Fill in
  589.                                 the     field     UserID    before    calling
  590.                                 muGetUserInfo().   The  search  will  be case
  591.                                 sensitive.
  592.       muKeyType_WUserID       - find  a user with a specific UserID.  Fill in
  593.                                 the     field     UserID    before    calling
  594.                                 muGetUserInfo().   The  search  will  be case
  595.                                 insensitive, wild cards are allowed.
  596.       muKeyType_WUserIDNext   - find  the  next  user with a specific UserID.
  597.                                 Use  this  only after you've made a call with
  598.                                 muKeyType_WUserID as keytype.
  599.       muKeyType_uid           - find a user with a specific uid.  Fill in the
  600.                                 field uid before calling muGetUserInfo().
  601.       muKeyType_gid           - find a user with a specific gid.  Fill in the
  602.                                 field gid before calling muGetUserInfo().
  603.       muKeyType_gidNext       - find  the next user with a specific gid.  Use
  604.                                 this  only  after  you've  made  a  call with
  605.                                 muKeyType_gid as keytype.
  606.       muKeyType_UserName      - find  a  user with a specific UserName.  Fill
  607.                                 in   the   field   UserName   before  calling
  608.                                 muGetUserInfo().   The  search  will  be case
  609.                                 insensitive.
  610.       muKeyType_WUserName     - find  a  user with a specific UserName.  Fill
  611.                                 in   the   field   UserName   before  calling
  612.                                 muGetUserInfo().   The  search  will  be case
  613.                                 insensitive, wild cards are allowed.
  614.       muKeyType_WUserNameNext - find  the next user with a specific UserName.
  615.                                 Use  this  only after you've made a call with
  616.                                 muKeyType_WUserName as keytype.
  617.  
  618.   INPUTS
  619.     info    - a muUserInfo structure, allocated with muAllocUserInfo.
  620.     keytype - the magic keytype.
  621.  
  622.   RESULT
  623.     info - a  pointer  to  the  supplied  muUserInfo structure, or NULL for a
  624.            failure.
  625.  
  626.   NOTE
  627.     Do  not  change  the  contents  of a muUserInfo structure before calls to
  628.     muGetUserInfo()      with      muKeyType_Next,     muKeyType_WUserIDNext,
  629.     muKeyType_gidNext or muKeyType_WUserNameNext.
  630.  
  631.   BUGS
  632.     none known
  633.  
  634.   SEE ALSO
  635.     muAllocUserInfo(), muGetUserInfo(), <libraries/multiuser.h>,
  636.     dos.library/SetOwner()
  637.  
  638. multiuser.library/muKill                             multiuser.library/muKill
  639.  
  640.   NAME  muKill()  (V39)
  641.  
  642.     success = muKill(task);
  643.  
  644.     BOOL muKill(struct Task *);
  645.     D0          D0
  646.  
  647.   DESCRIPTION
  648.     Cancel  a  specified  task.   You  cannot  commit  suicide  nor  kill the
  649.     MultiUser.server.  This call may be made only by root.
  650.  
  651.   INPUTS
  652.     task - a pointer to the task you want to kill.  This task may be frozen.
  653.  
  654.   RESULT
  655.     success - success indicator.
  656.  
  657.   NOTE
  658.     This  function  will also try to remove all windows and screens belonging
  659.     to the task.
  660.  
  661.   BUGS
  662.     Due  to the nature of AmigaOS, killing a task is a very dangerous action!
  663.     Use it at your own risk!
  664.  
  665.   SEE ALSO
  666.     muFreeze(), muUnfreeze()
  667.  
  668. multiuser.library/muLimitDOSSetProtectionuser.library/muLimitDOSSetProtection
  669.  
  670.   NAME  muLimitDOSSetProtection()  (V39)
  671.  
  672.     success = muLimitDOSSetProtection(flag);
  673.  
  674.     BOOL muLimitDOSSetProtection(BOOL);
  675.     D0                           D0
  676.  
  677.   DESCRIPTION
  678.     Limit  dos.library/SetProtection() to change only the protection bits for
  679.     the  owner  of  the  file.   If limiting is turned on, you can change the
  680.     protection  bits for GROUP and OTHER only via muSetProtection().  Default
  681.     limiting is turned off.
  682.  
  683.   INPUTS
  684.     flag - TRUE to turn limiting on, FALSE to turn limiting off.
  685.  
  686.   RESULT
  687.     success - success indicator.
  688.  
  689.   NOTE
  690.     This  function  is useful because a lot of programs change the protection
  691.     bits of a file without knowing about the new GROUP and OTHER flags.
  692.  
  693.   BUGS
  694.     Limiting  will  fail  if  someone  has  an  exclusive lock on the file or
  695.     directory the protection bits will be changed of.
  696.  
  697.   SEE ALSO
  698.     muSetProtection()
  699.  
  700. multiuser.library/muLoginA                         multiuser.library/muLoginA
  701.  
  702.   NAME  muLoginA()  (V39)
  703.  
  704.     user = muLoginA(taglist);
  705.  
  706.     ULONG muLoginA(struct TagItem *);
  707.     D0             A0
  708.  
  709.   DESCRIPTION
  710.     Login  to  the  system  and  remember  the last user.  Use the taglist to
  711.     specify options.
  712.  
  713.   TAGS
  714.     muT_Graphical  - (BOOL)
  715.                      Use  a  graphical  login instead of a console alike one.
  716.                      This works only if your pr_WindowPtr is not -1.  Default
  717.                      is FALSE.
  718.     muT_Input      - (BPTR)
  719.                      Specify  the  filehandle  to  read from.  Not used for a
  720.                      graphical login.  Default is Input().
  721.     muT_Output     - (BPTR)
  722.                      Specify  the  filehandle  to  write  to.  Not used for a
  723.                      graphical login.  Default is Output().
  724.     muT_PubScrName - (STRPTR)
  725.                      Specify  the  public  screen to open the login requester
  726.                      on.   Only  used  for a graphical login.  Default is the
  727.                      default public screen (mostly the Workbench screen).
  728.     muT_Task       - (struct Task *)
  729.                      Specify  the  task  you  want  to login.  Of course this
  730.                      works  only  for  your  own tasks (or for tasks owned by
  731.                      nobody),  unless you are the super user (root).  Default
  732.                      is the current task.
  733.     muT_Own        - (BOOL)
  734.                      Change  the  owner of the specified task to the owner of
  735.                      the  task  this call is made from.  Of course this works
  736.                      only for tasks owned by nobody, unless you are the super
  737.                      user (root).  Default is FALSE.
  738.     muT_Global     - (BOOL)
  739.                      Login  for  all tasks on the same level as the specified
  740.                      one.  Default is FALSE.
  741.     muT_UserID     - (STRPTR)
  742.                      Do  not  ask the user for a UserID but use the specified
  743.                      UserID.
  744.     muT_Password   - (STRPTR)
  745.                      Do not ask the user for a Password but use the specified
  746.                      Password.  If you use this, you must use muT_UserID too.
  747.     muT_NoLog      - (BOOL)
  748.                      Do  not  log  this action.  Of course this works only if
  749.                      you're root.  Default is FALSE.
  750.  
  751.   INPUTS
  752.     taglist - a pointer to a taglist (may be NULL).
  753.  
  754.   RESULT
  755.     user - the  user  that  logged in, or NULL for a failure.  The bits 31-16
  756.            specify  the  owner user id (uid), the bits 15-0 specify the owner
  757.            group id (gid).
  758.  
  759.   NOTE
  760.     The  tags  muT_UserID,  muT_Password and muT_NoLog are mainly intended to
  761.     let  programs  change  their  owner  to someone else temporarily (e.g.  a
  762.     daemon  with  a  set  'U'-bit owned by root).  If you want to restore the
  763.     previous  user  later  you  must  be  aware  of  the  fact that a call to
  764.     muLogoutA() may invoke a login request!
  765.  
  766.   BUGS
  767.     none known
  768.  
  769.   SEE ALSO
  770.     muLogoutA()
  771.  
  772. multiuser.library/muLogoutA                       multiuser.library/muLogoutA
  773.  
  774.   NAME  muLogoutA()  (V39)
  775.  
  776.     user = muLogoutA(taglist);
  777.  
  778.     ULONG muLogoutA(struct TagItem *);
  779.     D0              A0
  780.  
  781.   DESCRIPTION
  782.     Logout  and  restore the previous user.  If there was no previous user or
  783.     the  previous user was nobody, a login request will appear.  However, the
  784.     behavior  of  this  login request will be slightly different from that of
  785.     muLoginA(), more specifically the following actions will be taken:
  786.  
  787.       - the local variable 'Home' will be set to your home directory.
  788.       - the current directory will be set to your home directory.
  789.       - If  there  exists  a  script  file  called  '.profile'  in  the
  790.         configuration directory, it will be executed.
  791.  
  792.   TAGS
  793.     muT_Input      - see muLoginA()
  794.     muT_Output     - see muLoginA()
  795.     muT_Graphical  - see muLoginA()
  796.     muT_PubScrName - see muLoginA()
  797.     muT_Task       - see muLoginA()
  798.     muT_Own        - see muLoginA()
  799.     muT_Global     - see muLoginA()
  800.     muT_Quiet      - (BOOL)
  801.                      Never  request  for  a login, simply logout.  Default is
  802.                      FALSE.
  803.     muT_All        - (BOOL)
  804.                      Logout all previous users.  Default is FALSE.
  805.  
  806.   INPUTS
  807.     taglist - a pointer to a taglist (may be NULL).
  808.  
  809.   RESULT
  810.     user - the  user you're now, NULL for nobody.  The bits 31-16 specify the
  811.            owner  user  id  (uid),  the  bits 15-0 specify the owner group id
  812.            (gid).
  813.  
  814.   NOTE
  815.     If  there  was  no  previous user, this routine will not return until you
  816.     enter  a  valid UserID/password pair (unless you used the tag muT_Quiet)!
  817.     However,  this  tag  may  be  removed  in  future  releases  for enhanced
  818.     security.
  819.  
  820.   BUGS
  821.     none known
  822.  
  823.   SEE ALSO
  824.     muLoginA()
  825.  
  826. multiuser.library/muPasswd                         multiuser.library/muPasswd
  827.  
  828.   NAME  muPasswd()  (V39)
  829.  
  830.     success = muPasswd(oldpwd, newpwd);
  831.  
  832.     BOOL muPasswd(STRPTR, STRPTR);
  833.     D0            A0      A1
  834.  
  835.   DESCRIPTION
  836.     Change  the  password  for  the  owner of the task this routine is called
  837.     from.
  838.  
  839.   INPUTS
  840.     oldpwd - your old password.
  841.     newpwd - your new password.
  842.  
  843.   RESULT
  844.     success - indicates a successful password change.
  845.  
  846.   NOTE
  847.     For  the  format  of  the passwd-file, see <libraries/multiuser.h>.  This
  848.     format should be compatible with the Commodore AS255 passwd file.
  849.  
  850.   BUGS
  851.     none known
  852.  
  853.   SEE ALSO
  854.     muCheckPasswd(), <libraries/multiuser.h>
  855.  
  856. multiuser.library/muRemMonitor                 multiuser.library/muRemMonitor
  857.  
  858.   NAME  muRemMonitor()  (V39)
  859.  
  860.     muRemMonitor(monitor);
  861.  
  862.     void muRemMonitor(struct muMonitor *);
  863.                       A0
  864.  
  865.   DESCRIPTION
  866.     Remove a monitor from the system.  This call may be made only by root.
  867.  
  868.   INPUTS
  869.     monitor - a  muMonitor  structure  which  was  added  to the system using
  870.               muAddMonitor().
  871.  
  872.   RESULT
  873.     none
  874.  
  875.   BUGS
  876.     none known
  877.  
  878.   SEE ALSO
  879.     muAddMonitor(), <libraries/multiuser.h>
  880.  
  881. multiuser.library/muSetDefProtectionA   multiuser.library/muSetDefProtectionA
  882.  
  883.   NAME  muSetDefProtectionA()  (V39)
  884.  
  885.     success = muSetDefProtectionA(taglist);
  886.  
  887.     BOOL muSetDefProtectionA(struct TagItem);
  888.     D0                       A0
  889.  
  890.   DESCRIPTION
  891.     Set  the default protection bits related to a task.  Of course this works
  892.     only  for  your  own tasks (or for tasks owned by nobody), unless you are
  893.     the super user (root).
  894.  
  895.   TAGS
  896.     muT_Task          - (struct Task *)
  897.                         Specify  the  task  you  want  to  change the default
  898.                         protection bits for.  Default is the current task.
  899.     muT_DefProtection - (ULONG)
  900.                         The  default  protection  bits.   They must be in the
  901.                         format like defined in <dos/dos.h> (or take a look at
  902.                         <libraries/multiuser.h>   if   you   don't  have  3.0
  903.                         includes:-).  Default is FIBF_OTR_READ|FIBF_GRP_READ.
  904.     muT_Global        - (BOOL)
  905.                         Change  the  default protection bits for all tasks on
  906.                         the  same  level  as  the  specified one.  Default is
  907.                         FALSE.
  908.  
  909.   INPUTS
  910.     taglist - a pointer to a taglist (may be NULL).
  911.  
  912.   RESULT
  913.     success - success indicator.
  914.  
  915.   BUGS
  916.     none known
  917.  
  918.   SEE ALSO
  919.     muGetDefProtection(), <dos/dos.h>
  920.  
  921. multiuser.library/muSetProtection           multiuser.library/muSetProtection
  922.  
  923.   NAME  muSetProtection()  (V39)
  924.  
  925.     success = muSetProtection(name, mask);
  926.  
  927.     BOOL muSetProtection(STRPTR, LONG);
  928.     D0                   D1      D2
  929.  
  930.   DESCRIPTION
  931.     Set  the  protection  attributes on a file or directory.  See <dos/dos.h>
  932.     for a listing of protection bits and dos.library SetProtection() for more
  933.     information.
  934.     Using  this  function you can set the protection bits for GROUP and OTHER
  935.     too.
  936.  
  937.   INPUTS
  938.     name - pointer to a null-terminated string
  939.     mask - the protection mask required
  940.  
  941.   RESULT
  942.     success - success indicator.
  943.  
  944.   BUGS
  945.     none known
  946.  
  947.   SEE ALSO
  948.     muLimitDOSSetProtection(), dos.library/SetProtection(), <dos/dos.h>
  949.  
  950. multiuser.library/muUnfreeze                     multiuser.library/muUnfreeze
  951.  
  952.   NAME  muUnfreeze()  (V39)
  953.  
  954.     success = muUnfreeze(task);
  955.  
  956.     BOOL muUnfreeze(struct Task *);
  957.     D0            A0
  958.  
  959.   DESCRIPTION
  960.     Unfreeze  a  task  you  have frozen before.  This call may be made
  961.     only by root.
  962.  
  963.   INPUTS
  964.     task - a pointer to the task you want to unfreeze.
  965.  
  966.   RESULT
  967.     success - success indicator.
  968.  
  969.   BUGS
  970.     none known
  971.  
  972.   SEE ALSO
  973.     muKill(), muFreeze()
  974.  
  975. multiuser.library/muUserInfo2ExtOwner   multiuser.library/muUserInfo2ExtOwner
  976.  
  977.   NAME  muUserInfo2ExtOwner()  (V39)
  978.  
  979.     user = muUserInfo2ExtOwner(info);
  980.  
  981.     struct muExtOwner *muUserInfo2ExtOwner(struct muUserInfo *);
  982.     D0                                     A0
  983.  
  984.   DESCRIPTION
  985.     Convert a muUserInfo structure to a muExtOwner structure.
  986.  
  987.   INPUTS
  988.     info - a  pointer  to the information structure (may be NULL).  You still
  989.            have to free this structure by yourself.
  990.  
  991.   RESULT
  992.     user - a  pointer to another information structure.  This may (but mostly
  993.            won't)  be NULL for nobody.  You must use muFreeExtOwner() to free
  994.            this structure after use.  You may not alter this structure.
  995.  
  996.   BUGS
  997.     none known
  998.  
  999.   SEE ALSO
  1000.     muFreeExtOwner(), muGetTaskExtOwner(), muGetRelationshipA(),
  1001.     muGetUserInfo()
  1002.  
  1003.